package com.wicket.okrframework.biz.service.impl;

import cn.hutool.core.bean.BeanUtil;
import com.wicket.okrframework.base.service.MHostTypeService;
import com.wicket.okrframework.base.service.MPlatformAuthorizeService;
import com.wicket.okrframework.base.service.MRoleMemberService;
import com.wicket.okrframework.base.service.MSceneRoleService;
import com.wicket.okrframework.base.service.dto.req.*;
import com.wicket.okrframework.biz.service.dto.common.FrameworkSceneRoleDto;
import com.wicket.okrframework.biz.service.dto.req.*;
import com.wicket.okrframework.biz.service.dto.res.*;
import com.wicket.okrframework.common.util.CommonFunctionHelper;
import com.wicket.okrframework.common.util.RedisUtil;
import com.wicket.okrframework.dal.po.mbg.HostType;
import com.wicket.okrframework.dal.po.mbg.PlatformAuthorize;
import com.wicket.okrframework.dal.po.mbg.RoleMember;
import com.wicket.okrframework.dal.po.mbg.SceneRole;
import org.apache.skywalking.apm.toolkit.trace.Tag;
import org.apache.skywalking.apm.toolkit.trace.Tags;
import org.apache.skywalking.apm.toolkit.trace.Trace;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import javax.annotation.Resource;
import java.util.ArrayList;
import java.util.List;
import java.util.stream.Collectors;
import com.wicket.okrframework.common.exception.Assert;
import cn.hutool.core.collection.CollectionUtil;
import com.wicket.okrframework.biz.service.InductionRecordService;
import com.wicket.okrframework.biz.service.dto.common.BizAppSceneRelDto;
import com.wicket.okrframework.biz.service.AppSceneService;
import com.wicket.okrframework.base.service.MRoleTopBizSceneService;
import com.wicket.okrframework.dal.po.mbg.RoleTopBizScene;
import com.wicket.okrframework.biz.service.dto.common.RoleRecommendBizSceneDto;
import com.wicket.okrframework.base.service.MInductionRecordService;
import com.wicket.okrframework.dal.po.mbg.InductionRecord;
import com.wicket.okrframework.biz.service.nb.NbRole;

/**
 * @author ：
 * @date ：
 *
 *
 * @version 1.0
 */
@Service
public class RoleServiceImpl
        implements com.wicket.okrframework.biz.service.RoleService {

    @Resource
    private RedisUtil redisUtil;
    @Resource
    private MPlatformAuthorizeService mPlatformAuthorizeService;
    @Resource
    private MSceneRoleService mSceneRoleService;
    @Resource
    private MHostTypeService mHostTypeService;
    @Resource
    private MRoleMemberService mRoleMemberService;
@Resource
  private InductionRecordService inductionRecordService;
@Resource
  private AppSceneService appSceneService;
@Resource
 private MRoleTopBizSceneService mRoleTopBizSceneService;
@Resource
  private MInductionRecordService mInductionRecordService;
//@Resource
 //private MCustomFields2Service mCustomFields2Service;
@Resource
  private NbRole nbRole;

    /**
   * D1-2查询角色导航列表[623]
   * gen by moon at 10/2/2022, 7:43:46 AM
   */
  @Trace(operationName = "D1-2查询角色导航列表")
  @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Transactional(rollbackFor=Exception.class)
  @Override
  public QueryRoleMenuListRespDto queryRoleMenuList(QueryRoleMenuListReqDto reqDto){
    
      
      List<SceneRole> listSceneRole_1 =new ArrayList<>();
//步骤0: 1-1-06查询平台授权范围列表 - queryPlfAuthList
     List<PlatformAuthorize> listPlatformAuthorize =new ArrayList<>();
    QueryPlfAuthListReq queryPlfAuthListReq=new QueryPlfAuthListReq();
  queryPlfAuthListReq.setTypeCode("ROLE");//sourceId:31887_1
queryPlfAuthListReq.setAuthorizeTypeCode("SENCE");//sourceId:31877_1
queryPlfAuthListReq.setAuthorizedObject(CommonFunctionHelper.getBaseInfoFromLocal().getSpecSceneId());//CURRENT_SCENEID//sourceId:31878_1
queryPlfAuthListReq.setSubjectLifeCycle("CURRENTLY_VALID");//sourceId:34194_1
queryPlfAuthListReq.setIsAutoEmpower("FALSE");//sourceId:31883_1
queryPlfAuthListReq.setIsView("TRUE");//sourceId:31884_1
  
    /*1-1-06查询平台授权范围列表[1355]   */
    Assert.isNull(queryPlfAuthListReq.getTypeCode(),"D1-2查询角色导航列表-1-1-06查询平台授权范围列表-授权内容类型编码不能为空",false);
Assert.isNull(queryPlfAuthListReq.getAuthorizeTypeCode(),"D1-2查询角色导航列表-1-1-06查询平台授权范围列表-授权对象类型编码不能为空",false);
Assert.isNull(queryPlfAuthListReq.getAuthorizedObject(),"D1-2查询角色导航列表-1-1-06查询平台授权范围列表-授权对象ID不能为空",false);
Assert.isNull(queryPlfAuthListReq.getSubjectLifeCycle(),"D1-2查询角色导航列表-1-1-06查询平台授权范围列表-主体生命周期不能为空",false);
Assert.isNull(queryPlfAuthListReq.getIsAutoEmpower(),"D1-2查询角色导航列表-1-1-06查询平台授权范围列表-是否自动授权不能为空",false);
Assert.isNull(queryPlfAuthListReq.getIsView(),"D1-2查询角色导航列表-1-1-06查询平台授权范围列表-空间是否可见不能为空",false);
      listPlatformAuthorize = mPlatformAuthorizeService.queryPlfAuthList(queryPlfAuthListReq);
      
      
      
    
//步骤1: 1-2-08批量查询角色列表 - batchQueryRoleList
     List<SceneRole> listSceneRole =new ArrayList<>();
    if(listPlatformAuthorize !=null&& listPlatformAuthorize.size()>0 ){
          BatchQueryRoleListReq batchQueryRoleListReq=new BatchQueryRoleListReq();
  batchQueryRoleListReq.setRoleList(listPlatformAuthorize.stream().map(item->item.getAuthorizedContentId())
        .collect(Collectors.toList()));/*list-to-strings*///sourceId:31889_1
batchQueryRoleListReq.setSubjectLifeCycle("CURRENTLY_VALID");//sourceId:31890_1
batchQueryRoleListReq.setIsIdentity("FALSE");//sourceId:31892_1
  
    /*1-2-08批量查询角色列表[700]   */
    Assert.isNull(batchQueryRoleListReq.getSubjectLifeCycle(),"D1-2查询角色导航列表-1-2-08批量查询角色列表-主体生命周期不能为空",false);
Assert.isNull(batchQueryRoleListReq.getIsIdentity(),"D1-2查询角色导航列表-1-2-08批量查询角色列表-是否身份角色不能为空",false);
      listSceneRole = mSceneRoleService.batchQueryRoleList(batchQueryRoleListReq);
      
      
      listSceneRole_1 = listSceneRole;
           }
    
QueryRoleMenuListRespDto retData = new QueryRoleMenuListRespDto();
  retData.setRoleList(listSceneRole_1.stream().map(item -> BeanUtil.toBean(item, FrameworkSceneRoleDto.class)).collect(Collectors.toList()));//objList-to-objLists//sourceId:31907_1
  

  
  
return retData;
  }

    /**
   * D1-2查询角色列表[543]
   * gen by moon at 10/2/2022, 7:42:29 AM
   */
  @Trace(operationName = "D1-2查询角色列表")
  @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Transactional(rollbackFor=Exception.class)
  @Override
  public QueryRoleListRespDto queryRoleList(QueryRoleListReqDto reqDto){
    
      
      List<SceneRole> listSceneRole_1 =new ArrayList<>();
//步骤0: 1-2-08查询角色列表 - queryRoleList
     List<SceneRole> listSceneRole =new ArrayList<>();
    QueryRoleListReq queryRoleListReq=new QueryRoleListReq();
  if(reqDto!=null){
      queryRoleListReq.setRoleName(reqDto.getRoleName());//SimpleFieldAssign//sourceId:7874_1
queryRoleListReq.setRoleType(reqDto.getRoleType());//SimpleFieldAssign//sourceId:7877_1
queryRoleListReq.setIsIdentity(reqDto.getIsIdentity());//SimpleFieldAssign//sourceId:7879_1
queryRoleListReq.setAutomaticCreation(reqDto.getAutomaticCreation());//SimpleFieldAssign//sourceId:7880_1
queryRoleListReq.setPlatformData(reqDto.getPlatformData());//SimpleFieldAssign//sourceId:7881_1
queryRoleListReq.setSubjectLifeCycle(reqDto.getSubjectLifeCycle());//SimpleFieldAssign//sourceId:26151_1
queryRoleListReq.setIsArchive(reqDto.getIsArchive());//SimpleFieldAssign//sourceId:26152_1
//queryRoleListReq.setTempFreezeStatus(reqDto.getTempFreezeStatus());//SimpleFieldAssign//sourceId:34994_1
queryRoleListReq.setSpaceId(reqDto.getSpaceId());//SimpleFieldAssign//sourceId:34995_1
    }
  
    /*1-2-08查询角色列表[76]   */
    
      listSceneRole = mSceneRoleService.queryRoleList(queryRoleListReq);
      
      
      listSceneRole_1 = listSceneRole;
    
QueryRoleListRespDto retData = new QueryRoleListRespDto();
  retData.setRoleList(listSceneRole_1.stream().map(item -> BeanUtil.toBean(item, FrameworkSceneRoleDto.class)).collect(Collectors.toList()));//objList-to-objLists//sourceId:26166_1
  

  
  
return retData;
  }

    /**
   * D1-2新增角色[546]
   * gen by moon at 8/17/2022, 8:01:35 PM
   */
  @Trace(operationName = "D1-2新增角色")
  @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Transactional(rollbackFor=Exception.class)
  @Override
  public AddRoleRespDto addRole(AddRoleReqDto reqDto){
    
      
      String string_1 = null;
//步骤0: 1-2-08新增角色 - addRole
     String string = null;
    SceneRole sceneRole=new SceneRole();
  if(reqDto!=null){
      sceneRole.setRoleCode(reqDto.getRoleCode());//sourceId:7950_1
sceneRole.setRoleName(reqDto.getRoleName());//sourceId:7926_1
sceneRole.setRoleRemark(reqDto.getRoleRemark());//sourceId:7927_1
sceneRole.setRoleLogo(reqDto.getRoleLogo());//sourceId:33626_1
sceneRole.setRoleType(reqDto.getRoleType());//sourceId:7929_1
sceneRole.setIsIdentity(reqDto.getIsIdentity());//sourceId:7931_1
sceneRole.setAutomaticCreation(reqDto.getAutomaticCreation());//sourceId:7932_1
sceneRole.setPlatformData(reqDto.getPlatformData());//sourceId:7933_1
sceneRole.setHostTypeId(reqDto.getHostTypeId());//sourceId:7934_1
sceneRole.setSubjectLifeCycle(reqDto.getSubjectLifeCycle());//sourceId:27432_1
    }
  
    /*1-2-08新增角色[73]   */
    Assert.isNull(sceneRole.getRoleCode(),"D1-2新增角色-1-2-08新增角色-角色标识不能为空",false);
Assert.isNull(sceneRole.getRoleName(),"D1-2新增角色-1-2-08新增角色-角色名称不能为空",false);
Assert.isNull(sceneRole.getRoleType(),"D1-2新增角色-1-2-08新增角色-角色类型不能为空",false);
Assert.isNull(sceneRole.getIsIdentity(),"D1-2新增角色-1-2-08新增角色-是否身份角色不能为空",false);
Assert.isNull(sceneRole.getAutomaticCreation(),"D1-2新增角色-1-2-08新增角色-是否手动创建不能为空",false);
Assert.isNull(sceneRole.getPlatformData(),"D1-2新增角色-1-2-08新增角色-是否平台数据不能为空",false);
Assert.isNull(sceneRole.getHostTypeId(),"D1-2新增角色-1-2-08新增角色-宿主类型ID不能为空",false);
Assert.isNull(sceneRole.getSubjectLifeCycle(),"D1-2新增角色-1-2-08新增角色-主体生命周期不能为空",false);
      string = mSceneRoleService.addRole(sceneRole);
      
      string_1 = string;
    
AddRoleRespDto retData = new AddRoleRespDto();
  if(string_1!=null){
      retData.setRoleId(string_1);//sourceId:26206_1
    }
  

  
  
return retData;
  }

    /**
   * D1-2查询角色详情[1163]
   * gen by moon at 10/1/2022, 11:59:40 PM
   */
  @Trace(operationName = "D1-2查询角色详情")
  @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Transactional(rollbackFor=Exception.class)
  @Override
  public QueryRoleDetailRespDto queryRoleDetail(QueryRoleDetailReqDto reqDto){
    
      
      SceneRole sceneRole_1 =null;
HostType hostType_1 =null;
//步骤0: 1-2-08查询角色详情 - queryRoleDetail
     SceneRole sceneRole = null;
    QueryRoleDetailReq queryRoleDetailReq=new QueryRoleDetailReq();
  if(reqDto!=null){
      queryRoleDetailReq.setRoleId(reqDto.getRoleId());//SimpleFieldAssign//sourceId:25064_1
queryRoleDetailReq.setRoleCode(reqDto.getRoleCode());//SimpleFieldAssign//sourceId:25085_1
queryRoleDetailReq.setSubjectLifeCycle(reqDto.getSubjectLifeCycle());//SimpleFieldAssign//sourceId:35034_1
queryRoleDetailReq.setIsArchive(reqDto.getIsArchive());//SimpleFieldAssign//sourceId:35083_1
queryRoleDetailReq.setPlatformData(reqDto.getPlatformData());//SimpleFieldAssign//sourceId:35035_1
    }
  
    /*1-2-08查询角色详情[170]   */
    
      sceneRole = mSceneRoleService.queryRoleDetail(queryRoleDetailReq);
      
      
      sceneRole_1 = sceneRole;
    
//步骤1: 1-1-14查询宿主类型详情 - queryHostTypeDetail
     HostType hostType = null;
    if(sceneRole !=null){
          QueryHostTypeDetailReq queryHostTypeDetailReq=new QueryHostTypeDetailReq();
  if(sceneRole!=null){
      queryHostTypeDetailReq.setHostTypeId(sceneRole.getHostTypeId());//SimpleFieldAssign//sourceId:29755_1
    }
  
    /*1-1-14查询宿主类型详情[195]   */
    Assert.isNull(queryHostTypeDetailReq.getHostTypeId(),"D1-2查询角色详情-1-1-14查询宿主类型详情-宿主类型ID不能为空",false);
      hostType = mHostTypeService.queryHostTypeDetail(queryHostTypeDetailReq);
      
      
      hostType_1 = hostType;
           }
    
QueryRoleDetailRespDto retData = new QueryRoleDetailRespDto();
  if(sceneRole_1!=null){
      retData.setRoleId(sceneRole_1.getRoleId());//SimpleFieldAssign//sourceId:25099_1
retData.setRoleCode(sceneRole_1.getRoleCode());//SimpleFieldAssign//sourceId:25100_1
retData.setRoleName(sceneRole_1.getRoleName());//SimpleFieldAssign//sourceId:25101_1
retData.setRoleRemark(sceneRole_1.getRoleRemark());//SimpleFieldAssign//sourceId:25102_1
retData.setRoleLogo(sceneRole_1.getRoleLogo());//SimpleFieldAssign//sourceId:25103_1
retData.setRoleType(sceneRole_1.getRoleType());//SimpleFieldAssign//sourceId:25104_1
retData.setIsIdentity(sceneRole_1.getIsIdentity());//SimpleFieldAssign//sourceId:25106_1
retData.setAutomaticCreation(sceneRole_1.getAutomaticCreation());//SimpleFieldAssign//sourceId:25107_1
retData.setIsFreeze(sceneRole_1.getIsFreeze());//SimpleFieldAssign//sourceId:35103_1
//retData.setTempFreezeStatus(sceneRole_1.getTempFreezeStatus());//SimpleFieldAssign//sourceId:34328_1
retData.setPlatformData(sceneRole_1.getPlatformData());//SimpleFieldAssign//sourceId:25108_1
retData.setHostTypeId(sceneRole_1.getHostTypeId());//SimpleFieldAssign//sourceId:25109_1
retData.setSubjectLifeCycle(sceneRole_1.getSubjectLifeCycle());//SimpleFieldAssign//sourceId:25110_1
retData.setIsArchive(sceneRole_1.getIsArchive());//SimpleFieldAssign//sourceId:25111_1
retData.setOperationInductionId(sceneRole_1.getOperationInductionId());//SimpleFieldAssign//sourceId:25112_1
retData.setOperateTime(sceneRole_1.getOperateTime());//SimpleFieldAssign//sourceId:25113_1
    }
if(hostType_1!=null){
      retData.setHostTypeName(hostType_1.getHostTypeName());//SimpleFieldAssign//sourceId:29785_1
    }
  

  
  
return retData;
  }

    /**
   * D1-2修改自定义角色[640]
   * gen by moon at 10/2/2022, 7:43:58 AM
   */
  @Trace(operationName = "D1-2修改自定义角色")
  @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Transactional(rollbackFor=Exception.class)
  @Override
  public UpdateCustomRoleRespDto updateCustomRole(UpdateCustomRoleReqDto reqDto){
    
      
      //步骤0: 1-2-08修改角色 - updateRole
     boolean bOOLEAN ;
    SceneRole sceneRole=new SceneRole();
  if(reqDto!=null){
      sceneRole.setRoleId(reqDto.getRoleId());//SimpleFieldAssign//sourceId:34118_1
sceneRole.setRoleRemark(reqDto.getRoleRemark());//SimpleFieldAssign//sourceId:34119_1
sceneRole.setRoleLogo(reqDto.getRoleLogo());//SimpleFieldAssign//sourceId:34120_1
    }
  
    /*1-2-08修改角色[74]   */
    Assert.isNull(sceneRole.getRoleId(),"D1-2修改自定义角色-1-2-08修改角色-角色ID不能为空",false);
      bOOLEAN = mSceneRoleService.updateRole(sceneRole);
      
      
      
    
UpdateCustomRoleRespDto retData = new UpdateCustomRoleRespDto();
  
  

  
  
return retData;
  }

    /**
   * D1-2修改角色[548]
   * gen by moon at 8/10/2022, 3:23:52 AM
   */
  @Trace(operationName = "D1-2修改角色")
  @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Transactional(rollbackFor=Exception.class)
  @Override
  public UpdateRoleRespDto updateRole(UpdateRoleReqDto reqDto){
    
      
      //步骤0: 1-2-08修改角色 - updateRole
     boolean bOOLEAN ;
    SceneRole sceneRole=new SceneRole();
  if(reqDto!=null){
      sceneRole.setRoleId(reqDto.getRoleId());//sourceId:7952_1
sceneRole.setRoleCode(reqDto.getRoleCode());//sourceId:7977_1
sceneRole.setRoleName(reqDto.getRoleName());//sourceId:7953_1
sceneRole.setRoleRemark(reqDto.getRoleRemark());//sourceId:7954_1
sceneRole.setRoleLogo(reqDto.getRoleLogo());//sourceId:33631_1
sceneRole.setRoleType(reqDto.getRoleType());//sourceId:7956_1
sceneRole.setIsIdentity(reqDto.getIsIdentity());//sourceId:7958_1
sceneRole.setHostTypeId(reqDto.getHostTypeId());//sourceId:7961_1
sceneRole.setIsArchive(reqDto.getIsArchive());//sourceId:26234_1
sceneRole.setSubjectLifeCycle(reqDto.getSubjectLifeCycle());//sourceId:26233_1
    }
  
    /*1-2-08修改角色[74]   */
    
      bOOLEAN = mSceneRoleService.updateRole(sceneRole);
      
      
    
UpdateRoleRespDto retData = new UpdateRoleRespDto();
  
  

  
  
return retData;
  }

    /**
   * D1-2存档角色[1558]
   * gen by moon at 8/10/2022, 3:17:20 AM
   */
  @Trace(operationName = "D1-2存档角色")
  @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Transactional(rollbackFor=Exception.class)
  @Override
  public ArchiveRoleRespDto archiveRole(ArchiveRoleReqDto reqDto){
    
      
      //步骤0: 1-1-06查询平台授权范围列表 - queryPlfAuthList
     List<PlatformAuthorize> listPlatformAuthorize =new ArrayList<>();
    QueryPlfAuthListReq queryPlfAuthListReq=new QueryPlfAuthListReq();
  queryPlfAuthListReq.setTypeCode("ROLE");//sourceId:44622_1
queryPlfAuthListReq.setSubjectLifeCycle("EDITING");//sourceId:44618_1
if(reqDto!=null){
      queryPlfAuthListReq.setAuthorizedContentId(reqDto.getRoleId());//sourceId:44624_1
    }
  
    /*1-1-06查询平台授权范围列表（查正在编辑）[1355]   */
    Assert.isNull(queryPlfAuthListReq.getTypeCode(),"D1-2存档角色-1-1-06查询平台授权范围列表（查正在编辑）-授权内容类型编码不能为空",false);
Assert.isNull(queryPlfAuthListReq.getAuthorizedContentId(),"D1-2存档角色-1-1-06查询平台授权范围列表（查正在编辑）-授权内容ID不能为空",false);
Assert.isNull(queryPlfAuthListReq.getSubjectLifeCycle(),"D1-2存档角色-1-1-06查询平台授权范围列表（查正在编辑）-主体生命周期不能为空",false);
      listPlatformAuthorize = mPlatformAuthorizeService.queryPlfAuthList(queryPlfAuthListReq);
      
      
    
//步骤1: 1-1-06批量删除平台授权范围 - batchDeletePlfAuth
     boolean bOOLEAN ;
    if(listPlatformAuthorize!=null && listPlatformAuthorize.size()>0 ){
          List<String> listString=new ArrayList<>();
  listString = listPlatformAuthorize.stream().map(item->item.getPlatformAuthorizeId())
        .collect(Collectors.toList());//sourceId:44625_1
  
    /*1-1-06批量删除平台授权范围[1551]   */
    
      bOOLEAN = mPlatformAuthorizeService.batchDeletePlfAuth(listString);
      
      
           }
    
//步骤2: 1-1-06查询平台授权范围列表 - queryPlfAuthList
     List<PlatformAuthorize> listPlatformAuthorize_2 =new ArrayList<>();
    QueryPlfAuthListReq queryPlfAuthListReq_1=new QueryPlfAuthListReq();
  queryPlfAuthListReq_1.setTypeCode("ROLE");//sourceId:44632_1
queryPlfAuthListReq_1.setSubjectLifeCycle("CURRENTLY_VALID");//sourceId:44628_1
if(reqDto!=null){
      queryPlfAuthListReq_1.setAuthorizedContentId(reqDto.getRoleId());//sourceId:44634_1
    }
  
    /*1-1-06查询平台授权范围列表（查当前有效）[1355]   */
    Assert.isNull(queryPlfAuthListReq_1.getTypeCode(),"D1-2存档角色-1-1-06查询平台授权范围列表（查当前有效）-授权内容类型编码不能为空",false);
Assert.isNull(queryPlfAuthListReq_1.getAuthorizedContentId(),"D1-2存档角色-1-1-06查询平台授权范围列表（查当前有效）-授权内容ID不能为空",false);
Assert.isNull(queryPlfAuthListReq_1.getSubjectLifeCycle(),"D1-2存档角色-1-1-06查询平台授权范围列表（查当前有效）-主体生命周期不能为空",false);
      listPlatformAuthorize_2 = mPlatformAuthorizeService.queryPlfAuthList(queryPlfAuthListReq_1);
      
      
    
//步骤3: 1-1-06批量修改平台授权范围 - batchUpdatePlfAuth
     boolean bOOLEAN_1 ;
    if(listPlatformAuthorize_2!=null && listPlatformAuthorize_2.size()>0 ){
          List<PlatformAuthorize> listPlatformAuthorize_4=new ArrayList<>();
  for (PlatformAuthorize item : listPlatformAuthorize_2) {
                PlatformAuthorize oneItem = new PlatformAuthorize();
                oneItem.setPlatformAuthorizeId(item.getPlatformAuthorizeId());//sourceId:21013_2
oneItem.setSubjectLifeCycle("ARCHIVING");//sourceId:53150_2
oneItem.setIsArchive("TRUE");//sourceId:53151_2
               
                listPlatformAuthorize_4.add(oneItem);
            }//sourceId:44637_1
  
    /*1-1-06批量修改平台授权范围（存档）[1550]   */
    
      bOOLEAN_1 = mPlatformAuthorizeService.batchUpdatePlfAuth(listPlatformAuthorize_4);
      
      
           }
    
//步骤4: 1-2-08修改角色 - updateRole
     boolean bOOLEAN_2 ;
    SceneRole sceneRole=new SceneRole();
  sceneRole.setSubjectLifeCycle("ARCHIVING");//sourceId:44730_1
sceneRole.setIsArchive("TRUE");//sourceId:44731_1
if(reqDto!=null){
      sceneRole.setRoleId(reqDto.getRoleId());//sourceId:44722_1
    }
  
    /*1-2-08修改角色（存档）[74]   */
    Assert.isNull(sceneRole.getRoleId(),"D1-2存档角色-1-2-08修改角色（存档）-角色ID不能为空",false);
Assert.isNull(sceneRole.getSubjectLifeCycle(),"D1-2存档角色-1-2-08修改角色（存档）-主体生命周期不能为空",false);
Assert.isNull(sceneRole.getIsArchive(),"D1-2存档角色-1-2-08修改角色（存档）-是否存档不能为空",false);
      bOOLEAN_2 = mSceneRoleService.updateRole(sceneRole);
      
      
    
ArchiveRoleRespDto retData = new ArchiveRoleRespDto();
  
  

  
  
return retData;
  }

    /**
   * D1-2存档自定义角色[1722]
   * gen by moon at 10/2/2022, 12:23:03 AM
   */
  @Trace(operationName = "D1-2存档自定义角色")
  @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Transactional(rollbackFor=Exception.class)
  @Override
  public ArchiveCustomRoleRespDto archiveCustomRole(ArchiveCustomRoleReqDto reqDto){
    
      
      //步骤0: 1-2-08修改角色 - updateRole
     boolean bOOLEAN ;
    SceneRole sceneRole=new SceneRole();
  sceneRole.setSubjectLifeCycle("ARCHIVING");//sourceId:51852_1
sceneRole.setIsArchive("TRUE");//sourceId:51853_1
if(reqDto!=null){
      sceneRole.setRoleId(reqDto.getRoleId());//SimpleFieldAssign//sourceId:51844_1
    }
  
    /*1-2-08修改角色[74]   */
    
      bOOLEAN = mSceneRoleService.updateRole(sceneRole);
      
      
      
    
ArchiveCustomRoleRespDto retData = new ArchiveCustomRoleRespDto();
  
  

  
  
return retData;
  }
/**
   * D1-2查询角色列表ByCodes(公共)[3223]
   * gen by moon at 10/15/2022, 5:38:57 PM
   */
  @Trace(operationName = "D1-2查询角色列表ByCodes(公共)")
  @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Transactional(rollbackFor=Exception.class)
  @Override
  public BatchQueryRoleListByCodesComRespDto batchQueryRoleListByCodesCom(BatchQueryRoleListByCodesComReqDto reqDto){
    
      
      List<SceneRole> listSceneRole_1 =new ArrayList<>();
//步骤0: 1-2-08查询角色列表ByCodes - batchQueryRoleListByCodes
     List<SceneRole> listSceneRole =new ArrayList<>();
    BatchQueryRoleListByCodesReq batchQueryRoleListByCodesReq=new BatchQueryRoleListByCodesReq();
  batchQueryRoleListByCodesReq.setIsFreeze("FALSE");//sourceId:121845_1
batchQueryRoleListByCodesReq.setSubjectLifeCycle("CURRENTLY_VALID");//sourceId:121844_1
if(reqDto!=null){
      batchQueryRoleListByCodesReq.setRoleCodeList(reqDto.getRoleCodeList());//list-field-assign//sourceId:121842_1
batchQueryRoleListByCodesReq.setRoleType(reqDto.getRoleType());//SimpleFieldAssign//sourceId:315165_1
    }
  
    /*1-2-08查询角色列表ByCodes[3224]   */
    Assert.isNull(batchQueryRoleListByCodesReq.getIsFreeze(),"D1-2查询角色列表ByCodes(公共)-1-2-08查询角色列表ByCodes-是否冻结不能为空",false);
Assert.isNull(batchQueryRoleListByCodesReq.getSubjectLifeCycle(),"D1-2查询角色列表ByCodes(公共)-1-2-08查询角色列表ByCodes-主体生命周期不能为空",false);
      listSceneRole = mSceneRoleService.batchQueryRoleListByCodes(batchQueryRoleListByCodesReq);
      
      
      listSceneRole_1 = listSceneRole;
    
BatchQueryRoleListByCodesComRespDto retData = new BatchQueryRoleListByCodesComRespDto();
  retData.setRoleList(listSceneRole_1.stream().map(item -> BeanUtil.toBean(item, FrameworkSceneRoleDto.class)).collect(Collectors.toList()));//objList-to-objLists//sourceId:121909_1
  

  
  
return retData;
  }
/**
   * D1-查询角色详情(公共)[2747]
   * gen by moon at 10/15/2022, 5:38:58 PM
   */
  @Trace(operationName = "D1-查询角色详情(公共)")
  @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Transactional(rollbackFor=Exception.class)
  @Override
  public QueryRoleDetailComRespDto queryRoleDetailCom(QueryRoleDetailComReqDto reqDto){
    
      
      SceneRole sceneRole_1 =null;
//步骤0: 1-2-08查询角色详情 - queryRoleDetail
     SceneRole sceneRole = null;
    QueryRoleDetailReq queryRoleDetailReq=new QueryRoleDetailReq();
  if(reqDto!=null){
      queryRoleDetailReq.setRoleCode(reqDto.getRoleCode());//SimpleFieldAssign//sourceId:86510_1
    }
  
    /*1-2-08查询角色详情[170]   */
    
      sceneRole = mSceneRoleService.queryRoleDetail(queryRoleDetailReq);
      
      
      sceneRole_1 = sceneRole;
    
QueryRoleDetailComRespDto retData = new QueryRoleDetailComRespDto();
  if(sceneRole_1!=null){
      retData.setRoleId(sceneRole_1.getRoleId());//SimpleFieldAssign//sourceId:86526_1
retData.setRoleCode(sceneRole_1.getRoleCode());//SimpleFieldAssign//sourceId:100179_1
retData.setRoleName(sceneRole_1.getRoleName());//SimpleFieldAssign//sourceId:100180_1
    }
  

  
  
return retData;
  }
/**
   * D1查询用于权限角色列表(公共)[2189]
   * gen by moon at 5/21/2024, 2:01:58 AM
   */
  @Trace(operationName = "D1查询用于权限角色列表(公共)")
  @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Transactional(rollbackFor=Exception.class)
  @Override
  public QueryRoleOfPowerListComRespDto queryRoleOfPowerListCom(QueryRoleOfPowerListComReqDto reqDto){
    
      
      List<RoleMember> listRoleMember_1 =new ArrayList<>();
//步骤0: 1-2-08查询用于权限角色列表 - queryRoleOfPowerList
     List<RoleMember> listRoleMember =new ArrayList<>();
    QueryRoleOfPowerListReq queryRoleOfPowerListReq=new QueryRoleOfPowerListReq();
  if(reqDto!=null){
      queryRoleOfPowerListReq.setOriginalRoleMemberId(reqDto.getOriginalRoleMemberId());//SimpleFieldAssign//sourceId:64253_1
queryRoleOfPowerListReq.setSubjectLifeCycle(reqDto.getSubjectLifeCycle());//SimpleFieldAssign//sourceId:1811481_1
    }
  
    /*1-2-08查询用于权限角色列表[2184]   */
    Assert.isNull(queryRoleOfPowerListReq.getOriginalRoleMemberId(),"D1查询用于权限角色列表(公共)-1-2-08查询用于权限角色列表-身份人员ID不能为空",false);
      listRoleMember = mRoleMemberService.queryRoleOfPowerList(queryRoleOfPowerListReq)/*vcase invoke 本地 method 方法调用;*/;
      
      
      listRoleMember_1 = listRoleMember;
    
QueryRoleOfPowerListComRespDto retData = new QueryRoleOfPowerListComRespDto();
  retData.setRoleRelList(listRoleMember_1.stream().map(item -> BeanUtil.toBean(item, RoleRelDto.class)).collect(Collectors.toList()));//objList-to-objLists//sourceId:304415_1
  

  
  
return retData;
  }
/**
   * D1-2查询角色推荐到业务场景列表[5039]
   * gen by moon at 10/28/2022, 8:45:24 PM
   */
  @Trace(operationName = "D1-2查询角色推荐到业务场景列表")
  @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Transactional(rollbackFor=Exception.class)
  @Override
  public QueryRoleRecommendBizSceneListRespDto queryRoleRecommendBizSceneList(QueryRoleRecommendBizSceneListReqDto reqDto){
    
      
      List<RoleTopBizScene> listRoleTopBizScene_1 =new ArrayList<>();
//步骤0: 1-2-08-01查询角色推荐到业务场景列表 - queryRoleRecommendBizSceneList
     List<RoleTopBizScene> listRoleTopBizScene =new ArrayList<>();
    QueryRoleRecommendBizSceneListReq queryRoleRecommendBizSceneListReq=new QueryRoleRecommendBizSceneListReq();
  if(reqDto!=null){
      queryRoleRecommendBizSceneListReq.setRoleId(reqDto.getRoleId());//SimpleFieldAssign//sourceId:407514_1
queryRoleRecommendBizSceneListReq.setIsArchive(reqDto.getIsArchive());//SimpleFieldAssign//sourceId:407515_1
    }
  
    /*1-2-08-01查询角色推荐到业务场景列表[5050]   */
    Assert.isNull(queryRoleRecommendBizSceneListReq.getRoleId(),"D1-2查询角色推荐到业务场景列表-1-2-08-01查询角色推荐到业务场景列表-推荐的角色ID不能为空",false);
Assert.isNull(queryRoleRecommendBizSceneListReq.getIsArchive(),"D1-2查询角色推荐到业务场景列表-1-2-08-01查询角色推荐到业务场景列表-是否存档不能为空",false);
      listRoleTopBizScene = mRoleTopBizSceneService.queryRoleRecommendBizSceneList(queryRoleRecommendBizSceneListReq);
      
      
      listRoleTopBizScene_1 = listRoleTopBizScene;
    
QueryRoleRecommendBizSceneListRespDto retData = new QueryRoleRecommendBizSceneListRespDto();
  retData.setRoleRecommendBizSceneList(listRoleTopBizScene_1.stream().map(item -> BeanUtil.toBean(item, RoleRecommendBizSceneDto.class)).collect(Collectors.toList()));//objList-to-objLists//sourceId:407542_1
  

  
  
return retData;
  }
/**
   * D1-2新增角色推荐到业务场景[5041]
   * gen by moon at 10/28/2022, 8:45:26 PM
   */
  @Trace(operationName = "D1-2新增角色推荐到业务场景")
  @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Transactional(rollbackFor=Exception.class)
  @Override
  public AddRoleRecommendBizSceneRespDto addRoleRecommendBizScene(AddRoleRecommendBizSceneReqDto reqDto){
    
      
      String string_1 =null;
//virtualUsage 1-2-08查询角色详情  20523
      SceneRole sceneRole = null;
    QueryRoleDetailReq queryRoleDetailReq=new QueryRoleDetailReq();
  queryRoleDetailReq.setSubjectLifeCycle("CURRENTLY_VALID");//sourceId:407670_1_20523
if(reqDto!=null){
      queryRoleDetailReq.setRoleId(reqDto.getRoleId());//SimpleFieldAssign//sourceId:407669_1_20523
    }
  
    /*1-2-08查询角色详情[170]   */
    Assert.isNull(queryRoleDetailReq.getRoleId(),"D1-2新增角色推荐到业务场景-1-2-08查询角色详情-角色ID不能为空",false);
Assert.isNull(queryRoleDetailReq.getSubjectLifeCycle(),"D1-2新增角色推荐到业务场景-1-2-08查询角色详情-主体生命周期不能为空",false);
      sceneRole = mSceneRoleService.queryRoleDetail(queryRoleDetailReq);
      Assert.isTrue(sceneRole== null||  sceneRole.getRoleCode() ==null,"返回值不能为空",false);
      
      
//virtualUsage 1-2-08-01新增角色推荐到业务场景  20524
      String string = null;
    if(sceneRole !=null){
          RoleTopBizScene roleTopBizScene=new RoleTopBizScene();
  if(sceneRole!=null){
      roleTopBizScene.setRoleId(sceneRole.getRoleId());//SimpleFieldAssign//sourceId:407624_1_20524
roleTopBizScene.setRoleCode(sceneRole.getRoleCode());//SimpleFieldAssign//sourceId:407625_1_20524
    }
if(reqDto!=null){
      roleTopBizScene.setBizAppCode(reqDto.getBizAppCode());//SimpleFieldAssign//sourceId:407626_1_20524
roleTopBizScene.setBizSceneId(reqDto.getBizSceneId());//SimpleFieldAssign//sourceId:407627_1_20524
roleTopBizScene.setBizSenceCode(reqDto.getBizSenceCode());//SimpleFieldAssign//sourceId:407628_1_20524
roleTopBizScene.setSubjectLifeCycle(reqDto.getSubjectLifeCycle());//SimpleFieldAssign//sourceId:407629_1_20524
    }
  
    /*1-2-08-01新增角色推荐到业务场景[5046]   */
    Assert.isNull(roleTopBizScene.getRoleId(),"D1-2新增角色推荐到业务场景-1-2-08-01新增角色推荐到业务场景-推荐的角色ID不能为空",false);
Assert.isNull(roleTopBizScene.getRoleCode(),"D1-2新增角色推荐到业务场景-1-2-08-01新增角色推荐到业务场景-角色标识不能为空",false);
Assert.isNull(roleTopBizScene.getBizAppCode(),"D1-2新增角色推荐到业务场景-1-2-08-01新增角色推荐到业务场景-业务应用标识不能为空",false);
Assert.isNull(roleTopBizScene.getBizSceneId(),"D1-2新增角色推荐到业务场景-1-2-08-01新增角色推荐到业务场景-业务场景ID不能为空",false);
Assert.isNull(roleTopBizScene.getBizSenceCode(),"D1-2新增角色推荐到业务场景-1-2-08-01新增角色推荐到业务场景-业务场景编码不能为空",false);
Assert.isNull(roleTopBizScene.getSubjectLifeCycle(),"D1-2新增角色推荐到业务场景-1-2-08-01新增角色推荐到业务场景-主体生命周期不能为空",false);
      string = mRoleTopBizSceneService.addRoleRecommendBizScene(roleTopBizScene);
      
      
      string_1 = string;
           }
if((reqDto!= null&&  reqDto.getSubjectLifeCycle() !=null && reqDto.getSubjectLifeCycle().equals("CURRENTLY_VALID")||reqDto!= null&&  reqDto.getSubjectLifeCycle() !=null && reqDto.getSubjectLifeCycle().equals("EDITING"))) {
        //if((D1-2新增角色推荐到业务场景.主体生命周期 等于 当前有效 or D1-2新增角色推荐到业务场景.主体生命周期 等于 正在编辑))  20525
        
boolean bOOLEAN ;
    if(sceneRole !=null){
          SceneRole sceneRole_2=new SceneRole();
  sceneRole_2.setIsRecommend("TRUE");//sourceId:407603_1_20526
if(sceneRole!=null){
      sceneRole_2.setRoleId(sceneRole.getRoleId());//SimpleFieldAssign//sourceId:407593_1_20526
    }
  
    /*1-2-08修改角色[74]   */
    Assert.isNull(sceneRole_2.getRoleId(),"D1-2新增角色推荐到业务场景-1-2-08修改角色-角色ID不能为空",false);
Assert.isNull(sceneRole_2.getIsRecommend(),"D1-2新增角色推荐到业务场景-1-2-08修改角色-是否推荐不能为空",false);
      bOOLEAN = mSceneRoleService.updateRole(sceneRole_2);
      
      
      
           }
//processBranchName:正常结束 ,processBranchId:20527
        
      }
AddRoleRecommendBizSceneRespDto retData = new AddRoleRecommendBizSceneRespDto();
  if(string_1!=null){
      retData.setTopBizSceneRecordId(string_1);//SimpleFieldAssign//sourceId:407673_1
    }
  

  
  
return retData;
  }
/**
   * D1-2查询角色推荐列表[5040]
   * gen by moon at 11/4/2022, 7:16:00 AM
   */
  @Trace(operationName = "D1-2查询角色推荐列表")
  @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Transactional(rollbackFor=Exception.class)
  @Override
  public QueryRoleRecommendListRespDto queryRoleRecommendList(QueryRoleRecommendListReqDto reqDto){
    
      
      List<SceneRole> listSceneRole_1 =new ArrayList<>();
List<SceneRole> listSceneRole_3 =new ArrayList<>();
if((reqDto!= null&& reqDto.getBizAppCode() != null ||reqDto!= null&& reqDto.getBizSenceCode() != null )) {
        //if((D1-2查询角色推荐列表.业务应用标识 值不等于空  or D1-2查询角色推荐列表.业务场景编码 值不等于空 ))  20988

List<RoleTopBizScene> listRoleTopBizScene =new ArrayList<>();
    QueryRoleRecommendBizSceneListReq queryRoleRecommendBizSceneListReq=new QueryRoleRecommendBizSceneListReq();
  queryRoleRecommendBizSceneListReq.setIsArchive("FALSE");//sourceId:417720_1_20989
if(reqDto!=null){
      queryRoleRecommendBizSceneListReq.setBizAppCode(reqDto.getBizAppCode());//SimpleFieldAssign//sourceId:417716_1_20989
queryRoleRecommendBizSceneListReq.setBizSenceCode(reqDto.getBizSenceCode());//SimpleFieldAssign//sourceId:417718_1_20989
    }
  
    /*1-2-08-01查询角色推荐到业务场景列表[5050]   */
    Assert.isNull(queryRoleRecommendBizSceneListReq.getIsArchive(),"D1-2查询角色推荐列表-1-2-08-01查询角色推荐到业务场景列表-是否存档不能为空",false);
      listRoleTopBizScene = mRoleTopBizSceneService.queryRoleRecommendBizSceneList(queryRoleRecommendBizSceneListReq);

      
      
List<SceneRole> listSceneRole =new ArrayList<>();
    if(listRoleTopBizScene !=null&& !CollectionUtil.isEmpty(listRoleTopBizScene)&& listRoleTopBizScene.size()>0 ){
          BatchQueryRoleListReq batchQueryRoleListReq=new BatchQueryRoleListReq();
  batchQueryRoleListReq.setRoleList(listRoleTopBizScene.stream().map(item->item.getRoleId())
        .collect(Collectors.toList()));/*list-to-strings*///sourceId:417723_1_20990
batchQueryRoleListReq.setSubjectLifeCycle("CURRENTLY_VALID");//sourceId:417724_1_20990
if(reqDto!=null){
      batchQueryRoleListReq.setRoleType(reqDto.getRoleType());//SimpleFieldAssign//sourceId:417731_1_20990
batchQueryRoleListReq.setPlatformData(reqDto.getPlatformData());//SimpleFieldAssign//sourceId:417732_1_20990
batchQueryRoleListReq.setAutomaticCreation(reqDto.getAutomaticCreation());//SimpleFieldAssign//sourceId:417735_1_20990
batchQueryRoleListReq.setIsRecommend(reqDto.getIsRecommend());//SimpleFieldAssign//sourceId:417736_1_20990
    }

    /*1-2-08批量查询角色列表[700]   */
    Assert.isNull(batchQueryRoleListReq.getSubjectLifeCycle(),"D1-2查询角色推荐列表-1-2-08批量查询角色列表-主体生命周期不能为空",false);
      listSceneRole = mSceneRoleService.batchQueryRoleList(batchQueryRoleListReq);


      listSceneRole_1 = listSceneRole;
           }
//processBranchName:正常结束 ,processBranchId:20992

      }
else if((reqDto!= null&& reqDto.getBizAppCode() == null &&reqDto!= null&& reqDto.getBizSenceCode() == null )){
       //elseif((D1-2查询角色推荐列表.业务应用标识 值等于空  and D1-2查询角色推荐列表.业务场景编码 值等于空 ))  21121

List<SceneRole> listSceneRole_2 =new ArrayList<>();
    QueryRoleListReq queryRoleListReq=new QueryRoleListReq();
  queryRoleListReq.setSubjectLifeCycle("CURRENTLY_VALID");//sourceId:407405_1_21122
if(reqDto!=null){
      queryRoleListReq.setRoleType(reqDto.getRoleType());//SimpleFieldAssign//sourceId:407400_1_21122
queryRoleListReq.setAutomaticCreation(reqDto.getAutomaticCreation());//SimpleFieldAssign//sourceId:407427_1_21122
queryRoleListReq.setPlatformData(reqDto.getPlatformData());//SimpleFieldAssign//sourceId:407403_1_21122
queryRoleListReq.setIsRecommend(reqDto.getIsRecommend());//SimpleFieldAssign//sourceId:407407_1_21122
    }

    /*1-2-08查询角色列表[76]   */
    Assert.isNull(queryRoleListReq.getIsRecommend(),"D1-2查询角色推荐列表-1-2-08查询角色列表-是否推荐不能为空",false);
Assert.isNull(queryRoleListReq.getSubjectLifeCycle(),"D1-2查询角色推荐列表-1-2-08查询角色列表-主体生命周期不能为空",false);
      listSceneRole_2 = mSceneRoleService.queryRoleList(queryRoleListReq);


      listSceneRole_3 = listSceneRole_2;
//processBranchName:正常结束 ,processBranchId:21123

    }
QueryRoleRecommendListRespDto retData = new QueryRoleRecommendListRespDto();
  //todo dong 未找到匹配生成策略,请检查生成策略retData.setRoleList(listSceneRole_1.getRoleId()||listSceneRole_3.getRoleId()/listSceneRole_1.getRoleCode()||listSceneRole_3.getRoleCode()/listSceneRole_1.getRoleName()||listSceneRole_3.getRoleName()/listSceneRole_1.getRoleLogo()||listSceneRole_3.getRoleLogo()/listSceneRole_1.getRoleType()||listSceneRole_3.getRoleType()/listSceneRole_1.getIsIdentity()||listSceneRole_3.getIsIdentity()/listSceneRole_1.getIsRecommend()||listSceneRole_3.getIsRecommend()/listSceneRole_1.getOperationInductionId()||listSceneRole_3.getOperationInductionId()/listSceneRole_1.getOperateTime()||listSceneRole_3.getOperateTime()),数据源项; to( ==>tableName:undefined, fieldEnname:roleList ,uniqueId: 407454_1 uniqueSourceId:out_null_null) from (varName:undefined fieldundefined)
  if(CollectionUtil.isNotEmpty(listSceneRole_1)){
      retData.setRoleList(listSceneRole_1.stream().map(data->BeanUtil.toBean(data,FrameworkSceneRoleDto.class)).collect(Collectors.toList()));
  }

  if(CollectionUtil.isNotEmpty(listSceneRole_3)){
      retData.setRoleList(listSceneRole_3.stream().map(data->BeanUtil.toBean(data,FrameworkSceneRoleDto.class)).collect(Collectors.toList()));
  }

  
  
return retData;
  }
/**
   * D1-2删除角色推荐到业务场景[5042]
   * gen by moon at 10/28/2022, 8:45:34 PM
   */
  @Trace(operationName = "D1-2删除角色推荐到业务场景")
  @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Transactional(rollbackFor=Exception.class)
  @Override
  public DeleteRoleRecommendBizSceneRespDto deleteRoleRecommendBizScene(DeleteRoleRecommendBizSceneReqDto reqDto){
    
      
      //virtualUsage 1-2-08-01查询角色推荐到业务场景详情  20530
      RoleTopBizScene roleTopBizScene = null;
    QueryRoleRecommendBizSceneDetailReq queryRoleRecommendBizSceneDetailReq=new QueryRoleRecommendBizSceneDetailReq();
  queryRoleRecommendBizSceneDetailReq.setSubjectLifeCycle("EDITING");//sourceId:407733_1_20530
if(reqDto!=null){
      queryRoleRecommendBizSceneDetailReq.setTopBizSceneRecordId(reqDto.getTopBizSceneRecordId());//SimpleFieldAssign//sourceId:407731_1_20530
    }
  
    /*1-2-08-01查询角色推荐到业务场景详情[5049]   */
    Assert.isNull(queryRoleRecommendBizSceneDetailReq.getTopBizSceneRecordId(),"D1-2删除角色推荐到业务场景-1-2-08-01查询角色推荐到业务场景详情-推荐角色记录ID不能为空",false);
Assert.isNull(queryRoleRecommendBizSceneDetailReq.getSubjectLifeCycle(),"D1-2删除角色推荐到业务场景-1-2-08-01查询角色推荐到业务场景详情-主体生命周期不能为空",false);
      roleTopBizScene = mRoleTopBizSceneService.queryRoleRecommendBizSceneDetail(queryRoleRecommendBizSceneDetailReq);
      Assert.isTrue(roleTopBizScene== null||  roleTopBizScene.getRoleId() ==null,"返回值不能为空",false);
      
      
//virtualUsage 1-2-08-01删除角色推荐到业务场景  20531
      boolean bOOLEAN ;
    if(roleTopBizScene !=null){
          String string=new String();
  if(roleTopBizScene!=null){
      string=roleTopBizScene.getTopBizSceneRecordId();;//SimpleFieldAssign//sourceId:407740_1_20531
    }
  
    /*1-2-08-01删除角色推荐到业务场景[5048]   */
    Assert.isNull(string,"D1-2删除角色推荐到业务场景-1-2-08-01删除角色推荐到业务场景-推荐角色记录ID不能为空",false);
      bOOLEAN = mRoleTopBizSceneService.deleteRoleRecommendBizScene(string);
      
      
      
           }
//virtualUsage 1-2-08-01查询角色推荐到业务场景列表  20532
      List<RoleTopBizScene> listRoleTopBizScene =new ArrayList<>();
    if(roleTopBizScene !=null){
          QueryRoleRecommendBizSceneListReq queryRoleRecommendBizSceneListReq=new QueryRoleRecommendBizSceneListReq();
  queryRoleRecommendBizSceneListReq.setIsArchive("FALSE");//sourceId:407743_1_20532
if(roleTopBizScene!=null){
      queryRoleRecommendBizSceneListReq.setRoleId(roleTopBizScene.getRoleId());//SimpleFieldAssign//sourceId:407742_1_20532
    }
  
    /*1-2-08-01查询角色推荐到业务场景列表[5050]   */
    Assert.isNull(queryRoleRecommendBizSceneListReq.getRoleId(),"D1-2删除角色推荐到业务场景-1-2-08-01查询角色推荐到业务场景列表-推荐的角色ID不能为空",false);
Assert.isNull(queryRoleRecommendBizSceneListReq.getIsArchive(),"D1-2删除角色推荐到业务场景-1-2-08-01查询角色推荐到业务场景列表-是否存档不能为空",false);
      listRoleTopBizScene = mRoleTopBizSceneService.queryRoleRecommendBizSceneList(queryRoleRecommendBizSceneListReq);
      
      
      
           }
if((listRoleTopBizScene!= null&&  listRoleTopBizScene !=null && listRoleTopBizScene.size()==0)) {
        //if(1-2-08-01查询角色推荐到业务场景列表.角色推荐到业务场景列表数据集条数 等于 0)  20533
        
boolean bOOLEAN_1 ;
    if(roleTopBizScene !=null){
          SceneRole sceneRole=new SceneRole();
  sceneRole.setIsRecommend("FALSE");//sourceId:407751_1_20534
if(roleTopBizScene!=null){
      sceneRole.setRoleId(roleTopBizScene.getRoleId());//SimpleFieldAssign//sourceId:407750_1_20534
    }
  
    /*1-2-08修改角色[74]   */
    Assert.isNull(sceneRole.getRoleId(),"D1-2删除角色推荐到业务场景-1-2-08修改角色-角色ID不能为空",false);
Assert.isNull(sceneRole.getIsRecommend(),"D1-2删除角色推荐到业务场景-1-2-08修改角色-是否推荐不能为空",false);
      bOOLEAN_1 = mSceneRoleService.updateRole(sceneRole);
      
      
      
           }
//processBranchName:正常结束 ,processBranchId:20535
        
      }
DeleteRoleRecommendBizSceneRespDto retData = new DeleteRoleRecommendBizSceneRespDto();
  
  

  
  
return retData;
  }
/**
   * D1-2发布角色推荐到业务场景[5044]
   * gen by moon at 10/28/2022, 8:45:35 PM
   */
  @Trace(operationName = "D1-2发布角色推荐到业务场景")
  @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Transactional(rollbackFor=Exception.class)
  @Override
  public ReleaseRoleRecommendBizSceneRespDto releaseRoleRecommendBizScene(ReleaseRoleRecommendBizSceneReqDto reqDto){
    
      
      //步骤0: 1-2-08-01查询角色推荐到业务场景详情 - queryRoleRecommendBizSceneDetail
     RoleTopBizScene roleTopBizScene = null;
    QueryRoleRecommendBizSceneDetailReq queryRoleRecommendBizSceneDetailReq=new QueryRoleRecommendBizSceneDetailReq();
  queryRoleRecommendBizSceneDetailReq.setSubjectLifeCycle("EDITING");//sourceId:408151_1
if(reqDto!=null){
      queryRoleRecommendBizSceneDetailReq.setTopBizSceneRecordId(reqDto.getTopBizSceneRecordId());//SimpleFieldAssign//sourceId:408116_1
    }
  
    /*1-2-08-01查询角色推荐到业务场景详情[5049]   */
    Assert.isNull(queryRoleRecommendBizSceneDetailReq.getTopBizSceneRecordId(),"D1-2发布角色推荐到业务场景-1-2-08-01查询角色推荐到业务场景详情-推荐角色记录ID不能为空",false);
Assert.isNull(queryRoleRecommendBizSceneDetailReq.getSubjectLifeCycle(),"D1-2发布角色推荐到业务场景-1-2-08-01查询角色推荐到业务场景详情-主体生命周期不能为空",false);
      roleTopBizScene = mRoleTopBizSceneService.queryRoleRecommendBizSceneDetail(queryRoleRecommendBizSceneDetailReq);
      Assert.isTrue(roleTopBizScene== null||  roleTopBizScene.getTopBizSceneRecordId() ==null,"返回值不能为空",false);
      
      
    
//步骤1: 1-2-08-01修改角色推荐到业务场景 - updateRoleRecommendBizScene
     boolean bOOLEAN ;
    if(roleTopBizScene !=null){
          RoleTopBizScene roleTopBizScene_2=new RoleTopBizScene();
  roleTopBizScene_2.setSubjectLifeCycle("CURRENTLY_VALID");//sourceId:408063_1
if(roleTopBizScene!=null){
      roleTopBizScene_2.setTopBizSceneRecordId(roleTopBizScene.getTopBizSceneRecordId());//SimpleFieldAssign//sourceId:408062_1
    }
  
    /*1-2-08-01修改角色推荐到业务场景[5047]   */
    Assert.isNull(roleTopBizScene_2.getTopBizSceneRecordId(),"D1-2发布角色推荐到业务场景-1-2-08-01修改角色推荐到业务场景-推荐角色记录ID不能为空",false);
Assert.isNull(roleTopBizScene_2.getSubjectLifeCycle(),"D1-2发布角色推荐到业务场景-1-2-08-01修改角色推荐到业务场景-主体生命周期不能为空",false);
      bOOLEAN = mRoleTopBizSceneService.updateRoleRecommendBizScene(roleTopBizScene_2);
      
      
      
           }
    
ReleaseRoleRecommendBizSceneRespDto retData = new ReleaseRoleRecommendBizSceneRespDto();
  
  

  
  
return retData;
  }
/**
   * D1-2查询角色未推荐业务场景列表[5045]
   * gen by moon at 10/28/2022, 8:45:36 PM
   */
  @Trace(operationName = "D1-2查询角色未推荐业务场景列表")
  @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Transactional(rollbackFor=Exception.class)
  @Override
  public QueryRoleNoRecommendBizSceneListRespDto queryRoleNoRecommendBizSceneList(QueryRoleNoRecommendBizSceneListReqDto reqDto){
    
      
      QueryEnablingAppSceneListComRespDto queryEnablingAppSceneListComRespDto_1 =null;
List<RoleTopBizScene> listRoleTopBizScene_1 =new ArrayList<>();
//步骤0: D1-1查询赋能的应用业务场景列表(公共) - queryEnablingAppSceneListCom
     QueryEnablingAppSceneListComRespDto queryEnablingAppSceneListComRespDto = null;
    QueryEnablingAppSceneListComReqDto queryEnablingAppSceneListComReqDto=new QueryEnablingAppSceneListComReqDto();
  if(reqDto!=null){
      queryEnablingAppSceneListComReqDto.setBizAppCode(reqDto.getBizAppCode());//SimpleFieldAssign//sourceId:407561_1
queryEnablingAppSceneListComReqDto.setByBizAppId(reqDto.getByBizAppId());//SimpleFieldAssign//sourceId:407559_1
    }
  
    /*D1-1查询赋能的应用业务场景列表(公共)[4979]   */
    Assert.isNull(queryEnablingAppSceneListComReqDto.getBizAppCode(),"D1-2查询角色未推荐业务场景列表-D1-1查询赋能的应用业务场景列表(公共)-业务应用标识不能为空",false);
Assert.isNull(queryEnablingAppSceneListComReqDto.getByBizAppId(),"D1-2查询角色未推荐业务场景列表-D1-1查询赋能的应用业务场景列表(公共)-被赋能业务应用ID不能为空",false);
      queryEnablingAppSceneListComRespDto = appSceneService.queryEnablingAppSceneListCom(queryEnablingAppSceneListComReqDto);
      
      
      queryEnablingAppSceneListComRespDto_1 = queryEnablingAppSceneListComRespDto;
    
//步骤1: 1-2-08-01查询角色推荐到业务场景列表 - queryRoleRecommendBizSceneList
     List<RoleTopBizScene> listRoleTopBizScene =new ArrayList<>();
    QueryRoleRecommendBizSceneListReq queryRoleRecommendBizSceneListReq=new QueryRoleRecommendBizSceneListReq();
  queryRoleRecommendBizSceneListReq.setIsArchive("FALSE");//sourceId:407569_1
if(reqDto!=null){
      queryRoleRecommendBizSceneListReq.setRoleId(reqDto.getRoleId());//SimpleFieldAssign//sourceId:407563_1
    }
  
    /*1-2-08-01查询角色推荐到业务场景列表[5050]   */
    Assert.isNull(queryRoleRecommendBizSceneListReq.getRoleId(),"D1-2查询角色未推荐业务场景列表-1-2-08-01查询角色推荐到业务场景列表-推荐的角色ID不能为空",false);
Assert.isNull(queryRoleRecommendBizSceneListReq.getIsArchive(),"D1-2查询角色未推荐业务场景列表-1-2-08-01查询角色推荐到业务场景列表-是否存档不能为空",false);
      listRoleTopBizScene = mRoleTopBizSceneService.queryRoleRecommendBizSceneList(queryRoleRecommendBizSceneListReq);
      
      
      listRoleTopBizScene_1 = listRoleTopBizScene;
    
QueryRoleNoRecommendBizSceneListRespDto retData = new QueryRoleNoRecommendBizSceneListRespDto();
  retData.setRoleRecommendBizSceneList(listRoleTopBizScene_1.stream().map(item->item.getBizSceneId())
        .collect(Collectors.toList()));/*list-to-strings*///sourceId:407577_1
if(queryEnablingAppSceneListComRespDto_1!=null){
      retData.setBizAppSceneRelList(queryEnablingAppSceneListComRespDto_1.getBizAppSceneRelList().stream().map(item -> BeanUtil.toBean(item, BizAppSceneRelDto.class)).collect(Collectors.toList()));//objList-to-objLists//sourceId:407579_1
    }
  

  
  
return retData;
  }
/**
   * D1-2存档角色推荐到业务场景[5057]
   * gen by moon at 10/28/2022, 8:45:37 PM
   */
  @Trace(operationName = "D1-2存档角色推荐到业务场景")
  @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Transactional(rollbackFor=Exception.class)
  @Override
  public ArchiveRoleRecommendBizSceneRespDto archiveRoleRecommendBizScene(ArchiveRoleRecommendBizSceneReqDto reqDto){
    
      
      //virtualUsage 1-2-08-01修改角色推荐到业务场景  20536
      boolean bOOLEAN ;
    RoleTopBizScene roleTopBizScene=new RoleTopBizScene();
  roleTopBizScene.setSubjectLifeCycle("ARCHIVING");//sourceId:407797_1_20536
roleTopBizScene.setIsArchive("TRUE");//sourceId:407798_1_20536
if(reqDto!=null){
      roleTopBizScene.setTopBizSceneRecordId(reqDto.getTopBizSceneRecordId());//SimpleFieldAssign//sourceId:407796_1_20536
    }
  
    /*1-2-08-01修改角色推荐到业务场景[5047]   */
    Assert.isNull(roleTopBizScene.getTopBizSceneRecordId(),"D1-2存档角色推荐到业务场景-1-2-08-01修改角色推荐到业务场景-推荐角色记录ID不能为空",false);
Assert.isNull(roleTopBizScene.getSubjectLifeCycle(),"D1-2存档角色推荐到业务场景-1-2-08-01修改角色推荐到业务场景-主体生命周期不能为空",false);
Assert.isNull(roleTopBizScene.getIsArchive(),"D1-2存档角色推荐到业务场景-1-2-08-01修改角色推荐到业务场景-是否存档不能为空",false);
      bOOLEAN = mRoleTopBizSceneService.updateRoleRecommendBizScene(roleTopBizScene);
      
      
      
//virtualUsage 1-2-08-01查询角色推荐到业务场景列表  20537
      List<RoleTopBizScene> listRoleTopBizScene =new ArrayList<>();
    QueryRoleRecommendBizSceneListReq queryRoleRecommendBizSceneListReq=new QueryRoleRecommendBizSceneListReq();
  queryRoleRecommendBizSceneListReq.setSubjectLifeCycle("CURRENTLY_VALID");//sourceId:407773_1_20537
if(reqDto!=null){
      queryRoleRecommendBizSceneListReq.setRoleId(reqDto.getRoleId());//SimpleFieldAssign//sourceId:407768_1_20537
    }
  
    /*1-2-08-01查询角色推荐到业务场景列表[5050]   */
    Assert.isNull(queryRoleRecommendBizSceneListReq.getRoleId(),"D1-2存档角色推荐到业务场景-1-2-08-01查询角色推荐到业务场景列表-推荐的角色ID不能为空",false);
Assert.isNull(queryRoleRecommendBizSceneListReq.getSubjectLifeCycle(),"D1-2存档角色推荐到业务场景-1-2-08-01查询角色推荐到业务场景列表-主体生命周期不能为空",false);
      listRoleTopBizScene = mRoleTopBizSceneService.queryRoleRecommendBizSceneList(queryRoleRecommendBizSceneListReq);
      
      
      
if((listRoleTopBizScene!= null&&  listRoleTopBizScene !=null && listRoleTopBizScene.size()==0)) {
        //if(1-2-08-01查询角色推荐到业务场景列表.角色推荐到业务场景列表数据集条数 等于 0)  20538
        
boolean bOOLEAN_1 ;
    SceneRole sceneRole=new SceneRole();
  sceneRole.setIsRecommend("FALSE");//sourceId:407801_1_20539
if(reqDto!=null){
      sceneRole.setRoleId(reqDto.getRoleId());//SimpleFieldAssign//sourceId:407800_1_20539
    }
  
    /*1-2-08修改角色[74]   */
    Assert.isNull(sceneRole.getRoleId(),"D1-2存档角色推荐到业务场景-1-2-08修改角色-角色ID不能为空",false);
Assert.isNull(sceneRole.getIsRecommend(),"D1-2存档角色推荐到业务场景-1-2-08修改角色-是否推荐不能为空",false);
      bOOLEAN_1 = mSceneRoleService.updateRole(sceneRole);
      
      
      
//processBranchName:正常结束 ,processBranchId:20540
        
      }
ArchiveRoleRecommendBizSceneRespDto retData = new ArchiveRoleRecommendBizSceneRespDto();
  
  

  
  
return retData;
  }
/**
   * D1-2批量查询角色列表	[701]
   * gen by moon at 5/24/2023, 3:36:37 AM
   */
  @Trace(operationName = "D1-2批量查询角色列表	")
  @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Transactional(rollbackFor=Exception.class)
  @Override
  public BatchQueryRoleRespDto batchQueryRole(BatchQueryRoleReqDto reqDto){


      List<SceneRole> listSceneRole_1 =new ArrayList<>();
//步骤0: 1-2-08批量查询角色列表 - batchQueryRoleList
     List<SceneRole> listSceneRole =new ArrayList<>();
    BatchQueryRoleListReq batchQueryRoleListReq=new BatchQueryRoleListReq();
  if(reqDto!=null){
      batchQueryRoleListReq.setRoleList(reqDto.getRoleList());//list-field-assign//sourceId:14227_1
batchQueryRoleListReq.setSubjectLifeCycle(reqDto.getSubjectLifeCycle());//SimpleFieldAssign//sourceId:26598_1
batchQueryRoleListReq.setIsArchive(reqDto.getIsArchive());//SimpleFieldAssign//sourceId:26597_1
    }

    /*1-2-08批量查询角色列表[700]   */

      listSceneRole = mSceneRoleService.batchQueryRoleList(batchQueryRoleListReq)/*vcase invoke 本地 method 方法调用;*/;


      listSceneRole_1 = listSceneRole;

BatchQueryRoleRespDto retData = new BatchQueryRoleRespDto();
  retData.setRoleList(listSceneRole_1.stream().map(item -> BeanUtil.toBean(item, FrameworkSceneRoleDto.class)).collect(Collectors.toList()));//objList-to-objLists//sourceId:14955_1




return retData;
  }
/**
   * D1查询空间管理员(公共)[8945]
   * gen by moon at 4/2/2024, 11:30:53 PM
   */
  @Trace(operationName = "D1查询空间管理员(公共)")
  @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Transactional(rollbackFor=Exception.class)
  @Override
  public QuerySpaceManagerDetailComRespDto querySpaceManagerDetailCom(QuerySpaceManagerDetailComReqDto reqDto){


      InductionRecord inductionRecord_1 =null;
//步骤0: 1-2-13查询角色人员详情 - queryRoleMemberDetail
     RoleMember roleMember = null;
    QueryRoleMemberDetailReq queryRoleMemberDetailReq=new QueryRoleMemberDetailReq();
  queryRoleMemberDetailReq.setRoleCode("ADMIN");//CUSTOM_CONVENTION//sourceId:1671431_1
queryRoleMemberDetailReq.setRelationshipValid("FALSE");//sourceId:1671432_1
queryRoleMemberDetailReq.setSubjectLifeCycle("CURRENTLY_VALID");//sourceId:1692261_1
if(reqDto!=null){
      queryRoleMemberDetailReq.setSpaceId(reqDto.getSpaceId());//SimpleFieldAssign//sourceId:1671433_1
    }

    /*1-2-13查询角色人员详情[8946]   */
    Assert.isNull(queryRoleMemberDetailReq.getRoleCode(),"D1查询空间管理员(公共)-1-2-13查询角色人员详情-角色标识不能为空",false);
Assert.isNull(queryRoleMemberDetailReq.getRelationshipValid(),"D1查询空间管理员(公共)-1-2-13查询角色人员详情-是否失效不能为空",false);
Assert.isNull(queryRoleMemberDetailReq.getSubjectLifeCycle(),"D1查询空间管理员(公共)-1-2-13查询角色人员详情-主体生命周期不能为空",false);
Assert.isNull(queryRoleMemberDetailReq.getSpaceId(),"D1查询空间管理员(公共)-1-2-13查询角色人员详情-创建于空间ID不能为空",false);
      roleMember = mRoleMemberService.queryRoleMemberDetail(queryRoleMemberDetailReq)/*vcase invoke 本地 method 方法调用;*/;




//步骤1: 1-3-13查询就职记录详情 - queryinductionRecordDetail
     InductionRecord inductionRecord = null;
    if(roleMember !=null){
          QueryinductionRecordDetailReq queryinductionRecordDetailReq=new QueryinductionRecordDetailReq();
  queryinductionRecordDetailReq.setSubjectLifeCycle("CURRENTLY_VALID");//sourceId:1671518_1
if(roleMember!=null){
      queryinductionRecordDetailReq.setOriginalRoleMemberId(roleMember.getOriginalRoleMemberId());//SimpleFieldAssign//sourceId:1671517_1
    }
if(reqDto!=null){
      queryinductionRecordDetailReq.setSpaceId(reqDto.getSpaceId());//SimpleFieldAssign//sourceId:1671519_1
    }

    /*1-3-13查询就职记录详情[165]   */
    Assert.isNull(queryinductionRecordDetailReq.getOriginalRoleMemberId(),"D1查询空间管理员(公共)-1-3-13查询就职记录详情-身份人员ID不能为空",false);
Assert.isNull(queryinductionRecordDetailReq.getSubjectLifeCycle(),"D1查询空间管理员(公共)-1-3-13查询就职记录详情-主体生命周期不能为空",false);
Assert.isNull(queryinductionRecordDetailReq.getSpaceId(),"D1查询空间管理员(公共)-1-3-13查询就职记录详情-创建于空间ID不能为空",false);
      inductionRecord = mInductionRecordService.queryinductionRecordDetail(queryinductionRecordDetailReq)/*vcase invoke 本地 method 方法调用;*/;


      inductionRecord_1 = inductionRecord;
           }

QuerySpaceManagerDetailComRespDto retData = new QuerySpaceManagerDetailComRespDto();
  if(inductionRecord_1!=null){
      retData.setInductionRecordId(inductionRecord_1.getInductionRecordId());//SimpleFieldAssign//sourceId:1671542_1
    }




return retData;
  }
/**
   * D1分析分管领导部门业务角色(公共)[9145]
   * gen by moon at 4/2/2024, 11:34:19 PM
   */
  @Trace(operationName = "D1分析分管领导部门业务角色(公共)")
  @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Transactional(rollbackFor=Exception.class)
  @Override
  public AnalysisMemberLeaderRoleComRespDto analysisMemberLeaderRoleCom(AnalysisMemberLeaderRoleComReqDto reqDto){


      QueryReceiveFieldDetailRespDto receptionServiceRes_1 =null;
//virtualUsage 1-2-13查入参身份人员是否分管领导  65883
      RoleMember roleMember = null;
    QueryRoleMemberDetailReq queryRoleMemberDetailReq=new QueryRoleMemberDetailReq();
  queryRoleMemberDetailReq.setRoleCode("DEPT_LEADER");//CUSTOM_CONVENTION//sourceId:1692262_1_65883
queryRoleMemberDetailReq.setRelationshipValid("FALSE");//sourceId:1692263_1_65883
queryRoleMemberDetailReq.setSubjectLifeCycle("CURRENTLY_VALID");//sourceId:1692264_1_65883
if(reqDto!=null){
      queryRoleMemberDetailReq.setOriginalRoleMemberId(reqDto.getOriginalRoleMemberId());//SimpleFieldAssign//sourceId:1692271_1_65883
queryRoleMemberDetailReq.setSpaceId(reqDto.getSpaceId());//SimpleFieldAssign//sourceId:1692265_1_65883
    }

    /*1-2-13查入参身份人员是否分管领导[8946]   */
    Assert.isNull(queryRoleMemberDetailReq.getOriginalRoleMemberId(),"D1分析分管领导部门业务角色(公共)-1-2-13查入参身份人员是否分管领导-身份人员ID不能为空",false);
Assert.isNull(queryRoleMemberDetailReq.getRoleCode(),"D1分析分管领导部门业务角色(公共)-1-2-13查入参身份人员是否分管领导-角色标识不能为空",false);
Assert.isNull(queryRoleMemberDetailReq.getRelationshipValid(),"D1分析分管领导部门业务角色(公共)-1-2-13查入参身份人员是否分管领导-是否失效不能为空",false);
Assert.isNull(queryRoleMemberDetailReq.getSubjectLifeCycle(),"D1分析分管领导部门业务角色(公共)-1-2-13查入参身份人员是否分管领导-主体生命周期不能为空",false);
Assert.isNull(queryRoleMemberDetailReq.getSpaceId(),"D1分析分管领导部门业务角色(公共)-1-2-13查入参身份人员是否分管领导-创建于空间ID不能为空",false);
      roleMember = mRoleMemberService.queryRoleMemberDetail(queryRoleMemberDetailReq)/*vcase invoke 本地 method 方法调用;*/;



if((roleMember != null )) {
        //if(1-2-13查入参身份人员是否分管领导.出参 值不等于空 )  65884

//ModelCode: receptionService
        QueryReceiveFieldDetailRespDto receptionServiceRes = null;
    QueryReceiveFieldDetailReqDto receptionServiceReq=new QueryReceiveFieldDetailReqDto();
  receptionServiceReq.setDeptBusinessIdentity("TOP_LEVEL");//sourceId:1692276_1_65885

    /*M1约定出参高层部门业务角色[3715]  用于特殊方法接收上游入参。 */
    Assert.isNull(receptionServiceReq.getDeptBusinessIdentity(),"D1分析分管领导部门业务角色(公共)-M1约定出参高层部门业务角色-部门业务身份不能为空",false);
      receptionServiceRes = nbRole.queryReceiveFieldDetail(receptionServiceReq);


      receptionServiceRes_1 = receptionServiceRes;
      }
AnalysisMemberLeaderRoleComRespDto retData = new AnalysisMemberLeaderRoleComRespDto();
  if(receptionServiceRes_1!=null){
      retData.setDeptBusinessIdentity(receptionServiceRes_1.getDeptBusinessIdentity());//SimpleFieldAssign//sourceId:1692277_1
    }




return retData;
  }
    //
}
